﻿<src:WpfConfiguration x:Class="PowerModules.PowerStatusConfiguration" 
                      xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"        
                      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"           
                      xmlns:src="clr-namespace:MayhemWpf.UserControls;assembly=MayhemWpf" 
                      Width="500">
    <Grid>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="170" />
            <ColumnDefinition Width="330" />
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="20"/>
            <RowDefinition Height="25"/>
            <RowDefinition Height="25"/>
            <RowDefinition Height="auto"/>
        </Grid.RowDefinitions>
        <TextBlock Grid.Row="0" Name="ConfigMessage" Grid.Column="0" Grid.ColumnSpan="2" TextAlignment="Center" TextWrapping="WrapWithOverflow">Power Status Configuration: (Triggers only while discharging, except for Charging state)</TextBlock>
        <RadioButton Name="RadioBCS" VerticalAlignment="Center" GroupName="RadioPowerGroup" Grid.Row="1" Grid.Column="0" Content="Battery Charge State" Checked="TextChanged" />
        <RadioButton Name="RadioPercent" VerticalAlignment="Center" GroupName="RadioPowerGroup" Grid.Row="2" Grid.Column="0" Content="Battery Percentage" Checked="TextChanged" />
        <ComboBox Name="BatteryChargeSelectionList" SelectedIndex="0" VerticalAlignment="Center" Grid.Row="1" Grid.Column="1" IsEnabled="True" AllowDrop="True" IsReadOnly="True">
            <ComboBoxItem>Charging</ComboBoxItem>
            <ComboBoxItem>Low</ComboBoxItem>
            <ComboBoxItem>Critical</ComboBoxItem>
        </ComboBox>
        <Grid Grid.Row="2" Grid.Column="1">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="50"/>
                <ColumnDefinition />
            </Grid.ColumnDefinitions>
            <TextBox Name="BatteryPercentageBox" TextChanged="TextChanged" Grid.Column="0"/>
            <TextBlock  Grid.Column="1" VerticalAlignment="Center">&#160;% (integer, 3 to 98)</TextBlock>
        </Grid>
        <TextBlock Style="{StaticResource ConfigErrorMessage}" Name="textInvalid" Grid.Column="0" Grid.ColumnSpan="2" Grid.Row="3" />
    </Grid>
</src:WpfConfiguration>
